package work2;
//计算位数和取位
import java.util.Scanner;

public class DigitNumber {
    //递归求每一位
    public static void digit(int n){
        if(n<10){
            System.out.print(n);
            System.out.print(" ");
        }else{
            digit(n/10);
            System.out.print(n % 10);
            System.out.print(" ");
        }
    }
    public static void main(String[] args) {
        Scanner scanner=new Scanner(System.in);
        int n=scanner.nextInt();
        digit(n);
        System.out.print(n+"是");
        int num=0;//记录位数
        while(n>0){
            n=n/10;
            num++;
        }
        System.out.println(num+"位数");
    }
}
